#pragma once
#include <windows.h>
#include <string>
#include <nlohmann/json.hpp>

// 全局变量声明
extern HWND hWnd;
extern HINSTANCE hInst;
extern std::wstring Username;
extern int CardCount;
extern HWND GameWindow;
extern HWND RankingListWindow;
extern nlohmann::json GameData;

// 结构体声明
// 主（默认）窗口属性
struct MainWindowAttributes {
    // （客户区）窗口大小
    RECT rect;
    int width;
    int width_center;
    int height;
    int height_center;
};
extern MainWindowAttributes st_mwa;

// 函数声明
LRESULT CALLBACK WindowProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
BOOL RegisterWindowClass();
BOOL RegisterGameWindowClass();
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
                   LPSTR lpCmdLine, int nCmdShow);